<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"%>
<%@ taglib uri="http://java.sun.com/jstl/fmt_rt" prefix="fmt"%>
<%
	String ctx=request.getContextPath();
%>
<div class="lefter">
	<div class="box">
		<h2>商品分类</h2>
		<dl>
			<c:forEach items="${categories}" var="category">
				<c:if test="${category.epcId==category.epcParentId}">
					<dt>${category.epcName}</dt>
				</c:if>
				<c:if test="${category.epcId!=category.epcParentId}">
					<dd><a href="<%=ctx%>/home/productList?categoryId=${category.epcId}">${category.epcName}</a></dd>
				</c:if>
			</c:forEach>
		</dl>
	</div>
	<div class="spacer"></div>
	<div class="last-view">
		<h2>最近浏览</h2>
		<dl class="clearfix">
			<c:forEach items="${recentProducts}" var="product">
				<dt>
					<img style="width: 30px;height: 20px;"
						 src="${pageContext.request.contextPath}/static/files/${product.epFileName}"/>
				</dt>
				<dd>
					<a href="<%=ctx%>/product/productView?entityId=${product.epId}">${product.epName}</a>
				</dd>
			</c:forEach>
		</dl>
	</div>
</div>